package org.apache.dolphinscheduler.dao.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

/**
 * <p>
 *
 * </p>
 *
 * @author denggh
 * @since 2023-06-15
 */
@TableName("t_ds_product")
public class Product implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 资源编号
     */
    private String productNo;

    /**
     * 资源名称
     */
    private String productName;

    /**
     * worker ip
     */
    private String host;

    /**
     * 资源类型 0 = 虚拟资源 1 = 物理资源 2 = 模型
     */
    private Integer productType;

    /**
     * 资源来源 0 = 平台 1 = 个人 2 = 企业
     */
    private Integer productSource;

    /**
     * 计费类型 0 = 按量计费
     */
    private Integer billType;

    /**
     * 计费规则 0 = 标准计费 1=梯度计费
     */
    private Integer billRule;

    /**
     * 资源单价
     */
    private BigDecimal price;

    /**
     * 部署时间
     */
    private Date deployTime;

    /**
     * cpu核数
     */
    private Integer vCpu;

    /**
     * 内存大小
     */
    private Long memory;

    /**
     * 平台服务费比例
     */
    private BigDecimal serviceRatio;

    /**
     * 存储大小
     */
    private Long dataTotal;

    private Date createTime;

    private Date updateTime;

    @TableField(exist = false)
    private BigDecimal totalIncome;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getProductNo() {
        return productNo;
    }

    public void setProductNo(String productNo) {
        this.productNo = productNo;
    }

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public String getHost() {
        return host;
    }

    public void setHost(String host) {
        this.host = host;
    }

    public Integer getProductType() {
        return productType;
    }

    public void setProductType(Integer productType) {
        this.productType = productType;
    }

    public Integer getProductSource() {
        return productSource;
    }

    public void setProductSource(Integer productSource) {
        this.productSource = productSource;
    }

    public Integer getBillType() {
        return billType;
    }

    public void setBillType(Integer billType) {
        this.billType = billType;
    }

    public Integer getBillRule() {
        return billRule;
    }

    public void setBillRule(Integer billRule) {
        this.billRule = billRule;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public Date getDeployTime() {
        return deployTime;
    }

    public void setDeployTime(Date deployTime) {
        this.deployTime = deployTime;
    }

    public Integer getvCpu() {
        return vCpu;
    }

    public void setvCpu(Integer vCpu) {
        this.vCpu = vCpu;
    }

    public Long getMemory() {
        return memory;
    }

    public void setMemory(Long memory) {
        this.memory = memory;
    }

    public Long getDataTotal() {
        return dataTotal;
    }

    public void setDataTotal(Long dataTotal) {
        this.dataTotal = dataTotal;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public BigDecimal getServiceRatio() {
        return serviceRatio;
    }

    public void setServiceRatio(BigDecimal serviceRatio) {
        this.serviceRatio = serviceRatio;
    }

    public BigDecimal getTotalIncome() {
        return totalIncome;
    }

    public void setTotalIncome(BigDecimal totalIncome) {
        this.totalIncome = totalIncome;
    }

    @Override
    public String toString() {
        return "Product{" +
                "id=" + id +
                ", productNo='" + productNo + '\'' +
                ", productName='" + productName + '\'' +
                ", host='" + host + '\'' +
                ", productType=" + productType +
                ", productSource=" + productSource +
                ", billType=" + billType +
                ", billRule=" + billRule +
                ", price=" + price +
                ", deployTime=" + deployTime +
                ", vCpu=" + vCpu +
                ", memory=" + memory +
                ", serviceRatio=" + serviceRatio +
                ", dataTotal=" + dataTotal +
                ", createTime=" + createTime +
                ", updateTime=" + updateTime +
                '}';
    }
}
